{{include file="user/u_header.html"}}
<div class="w998 u_main clear">
	{{include file="user/u_leftMenu.html"}}	
    <!--右侧开始-->
    <div class="Fr right">
    龙付通绑定
    {{if $userItem.LFT==1}}
        已绑定
    {{else}}
     <form id="form1" name="form1" method="post" action="user.php?ctl=pay&act=lft&tp=reg">
        手机号码: {{$userItem.USERNAME}} <input type="button" id="GetVerify" value="发送验证码" onclick="get_verify()" /><br />
        手机验证码: <input type="text" name="id_code" id="id_code" /><br />
        <input type="submit" name="btnsubmit">
    </form>
    {{/if}}
    </div>
    <!--右侧结束-->
</div>
<script type="text/javascript">
                var times = 30;
                var isinerval;
                function CountDown() {
                    if (times < 1) {
                        $("#GetVerify").val("获取短信验证码").attr("disabled", false);
                        clearInterval(isinerval);
                        return;
                    }
                    $("#GetVerify").val(times+"秒后重获验证码");
                    times--;
                }
                function get_verify() {
                    $.get("user.php?ctl=pay&act=lft&sms=1",{ random:Math.random()}, function(data){
                        if(data=="1") {
                           times = 30;
                            $("#GetVerify").attr("disabled", true);
                            isinerval = setInterval("CountDown()", 1000);
                        } else {
                            alert("短信发送失败");
                        }
                    },'json');
                    
                }


</script>
{{include file="user/u_footer.html"}}
